﻿using System;
using System.Collections.Generic;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Audio;
using Microsoft.Xna.Framework.Content;
using Microsoft.Xna.Framework.Graphics;
using Microsoft.Xna.Framework.Input;
using Microsoft.Xna.Framework.Storage;

namespace XnaSuperGame
{
	public class GObject
	{
		public Texture2D sprite;
		public Vector2 position;
		public float rotation;
		public Vector2 center;
		public Vector2 velocity;
		public bool alive;

		public GObject(Texture2D loadedTexture)
		{
			rotation = 0.0f;
			position = Vector2.Zero;

			sprite = loadedTexture;

			center = new Vector2(
				 sprite.Width / 2, sprite.Height / 2);

			velocity = Vector2.Zero;
			alive = false;
		}

		public Rectangle HitBox()
		{
			return new Rectangle((int)position.X, (int)position.Y, sprite.Width, sprite.Height);
		}

	}
}


